from rest_framework.serializers import ModelSerializer
from  rest_framework import  serializers
from meiduo01.models import *
class HomeSer(ModelSerializer):
    class Meta:
        model = Category
        fields = '__all__'
class GoodsSer(ModelSerializer):
    class Meta:
        model = Goods
        fields = '__all__'
class CareSer(ModelSerializer):
    class Meta:
        model = Cart
        fields = '__all__'

class ShowcareSer(ModelSerializer):
    goods = GoodsSer()
    class Meta:
        model = Cart
        fields = '__all__'

class OrderInfoSer(ModelSerializer):
    class Meta:
        model = OrderInfo
        fields = '__all__'
class OrderDetailSer(ModelSerializer):
    class Meta:
        model = OrderDetail
        fields = '__all__'
